/**
 * 
 */

$(function(){
	var $idea_feedback_theme = $("#form-field-1");
	var $idea_feedback_content = $("#form-field-comment");
	var $submit = $("button.submit");
	
	$submit.click(function(){
		var idea_feedback_theme = $idea_feedback_theme.val();
		var idea_feedback_content = $idea_feedback_content.val();
		if(idea_feedback_content!=""){
			$.post("Opinion_feedback",{"idea_feedback_theme":idea_feedback_theme,"idea_feedback_content":idea_feedback_content},function(data,status){
				if(data.result==true){
					//do not
					jSuccess("意见已反馈等待处理",{HorizontalPosition : "center",VerticalPosition : "center",ShowOverlay : false});
				}else{
					alert("数据发送失败");
				}
			},"json");	
		}else{
			jError("类容不能为空",{HorizontalPosition : "center",VerticalPosition : "center",ShowOverlay : false});
		}
		
	});
});